<?php

$data = file_get_contents("http://www.soso.com/tx?ie=utf8&pid=&query=php&w=&sut=581&sst0=1544758248455&lkt=3%2C1544758247874%2C1544758248046");


$preg = "/<a href=\"\?user_ip.+?\" id=\"sogou_99999_\d\">(.+?)<\/a>/";

$c = preg_match_all($preg,$data,$out);


var_dump($c,$out);


// <a href="?user_ip=219.136.3.122&sourceid=hint&bh=1&hintidx=17&query=%E4%BB%80%E4%B9%88%E6%98%AFphp%E6%8A%80%E6%9C%AF&w=01020600&interation=&interV=kKIOkrELjbgLmLkEk70TkKIMkLELjboImLkEk74TkKIMkrELjbkRmLkEmrELjbgRmLkEkLY=_-1462299959&htdbg=on&ie=utf8&s_from=hint_last" id="sogou_99999_4">什么是php技术</a>